package com.cesgroup.zw.spring.boot.library.echarts.pieAndGauge.complex;

import com.cesgroup.zw.spring.boot.echarts.component.series.Pie;
import com.cesgroup.zw.spring.boot.echarts.enums.Position;
import com.cesgroup.zw.spring.boot.echarts.model.style.LabelStyle;

/**
 * @author ytj
 * @date 2019/7/4 16:55
 */
@SuppressWarnings("serial")
public class ComplexPieSeries extends Pie{
    public ComplexPieSeries(ComplexPieAndGaugeParam param){
        this.setType("pie");
        this.setRadius(new String[]{"35%","50%"});
        this.setCenter(new String[]{"50%","50%"});
        this.setSilent(true);
        this.setClockwise(true);
        this.setStartAngle(90);
        this.setZ(0);
        this.setZlevel(0);
        this.setLabel(new LabelStyle(){{
            this.setPosition(Position.center);
        }});
        this.setData(param.getDataset());
    }
}
